﻿package com.ufenlei.LTS{

	import flash.display.MovieClip;
	import flash.display.Shape;

	public class RoundRectBody extends Body {
		private var roundRectBodyWidth:int;
		private var roundRectBodyHeight:int;
		private var ellipseWidth:int;
		private var ellipseHeight:int;
		var roundRect:Shape = new Shape();
		public function RoundRectBody(RRW:int = 0,RRH:int = 0,EW:int = 0,EH:int = 0) {
			roundRectBodyWidth = RRW;
			roundRectBodyHeight = RRH;
			ellipseWidth = EW;
			ellipseHeight = EH;
			roundRect.graphics.beginFill(0XFFFFFF);
			roundRect.graphics.drawRoundRect(0,0,roundRectBodyWidth,roundRectBodyHeight,ellipseWidth,ellipseHeight);
			roundRect.graphics.endFill();
			roundRect.graphics.lineStyle(1,0X8C8C8C);
			roundRect.graphics.drawRoundRect(0,0,roundRectBodyWidth,roundRectBodyHeight,ellipseWidth,ellipseHeight);
            this.addChild(roundRect);			
		}
		public function get bodyWidth(){
			return(roundRect.width);
		}
		public function get bodyHeight(){
			return(roundRect.height);
		}
		public function ChangeWidth(wid:int) {
			this.width=wid;
		}
		public function ChangeHeight(hei:int) {
			this.height=hei;
		}
	}
}